# -*- coding: utf-8 -*-
from __future__ import unicode_literals
from django.http import HttpResponse
from web.models import  webPost
from django.template import  loader, Context
from django.shortcuts import render
from xadmin.views import *


def RegDn(request):
    context = {}
    context['hello'] = 'Hello World!'
    return render(request, 'RegDn.html', context)


# Create your views here.
def archive(request):
    posts =webPost.objects.all()
    t=loader.get_template("licence.html")
    #c=Context({'posts':posts})
    return  HttpResponse(t.render({'posts':posts}))

class TerminalPlugin(BaseAdminPlugin):
    is_execute = True
    readonly_fields = ['title']
    def init_request(self, *arg, **kwargs):
        return self.is_execute



